3.11.19 \(\int \frac {\sqrt {a+i a \tan (e+f x)}}{\sqrt {c-i c \tan (e+f x)}} \, dx\) [1019]

Optimal. Leaf size=41 \[ -\frac {i \sqrt {a+i a \tan (e+f x)}}{f \sqrt {c-i c \tan (e+f x)}} \]

[Out]

-I*(a+I*a*tan(f*x+e))^(1/2)/f/(c-I*c*tan(f*x+e))^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.06, antiderivative size = 41, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 35, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.057, Rules used = {3604, 37} \begin {gather*} -\frac {i \sqrt {a+i a \tan (e+f x)}}{f \sqrt {c-i c \tan (e+f x)}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + I*a*Tan[e + f*x]]/Sqrt[c - I*c*Tan[e + f*x]],x]

[Out]

((-I)*Sqrt[a + I*a*Tan[e + f*x]])/(f*Sqrt[c - I*c*Tan[e + f*x]])

Rule 37

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(a + b*x)^(m + 1)*((c + d*x)^(n +
1)/((b*c - a*d)*(m + 1))), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[b*c - a*d, 0] && EqQ[m + n + 2, 0] && NeQ
[m, -1]

Rule 3604

Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Dist
[a*(c/f), Subst[Int[(a + b*x)^(m - 1)*(c + d*x)^(n - 1), x], x, Tan[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f,
m, n}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 + b^2, 0]

Rubi steps

\begin {align*} \int \frac {\sqrt {a+i a \tan (e+f x)}}{\sqrt {c-i c \tan (e+f x)}} \, dx &=\frac {(a c) \text {Subst}\left (\int \frac {1}{\sqrt {a+i a x} (c-i c x)^{3/2}} \, dx,x,\tan (e+f x)\right )}{f}\\ &=-\frac {i \sqrt {a+i a \tan (e+f x)}}{f \sqrt {c-i c \tan (e+f x)}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.79, size = 64, normalized size = 1.56 \begin {gather*} \frac {\cos (e+f x) (-i \cos (e+f x)+\sin (e+f x)) \sqrt {a+i a \tan (e+f x)} \sqrt {c-i c \tan (e+f x)}}{c f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + I*a*Tan[e + f*x]]/Sqrt[c - I*c*Tan[e + f*x]],x]

[Out]

(Cos[e + f*x]*((-I)*Cos[e + f*x] + Sin[e + f*x])*Sqrt[a + I*a*Tan[e + f*x]]*Sqrt[c - I*c*Tan[e + f*x]])/(c*f)

________________________________________________________________________________________

Maple [A]
time = 0.37, size = 63, normalized size = 1.54

method result size
risch \(-\frac {i \sqrt {\frac {a \,{\mathrm e}^{2 i \left (f x +e \right )}}{{\mathrm e}^{2 i \left (f x +e \right )}+1}}}{\sqrt {\frac {c}{{\mathrm e}^{2 i \left (f x +e \right )}+1}}\, f}\) \(50\)
derivativedivides \(-\frac {i \sqrt {a \left (1+i \tan \left (f x +e \right )\right )}\, \sqrt {-c \left (i \tan \left (f x +e \right )-1\right )}\, \left (i \tan \left (f x +e \right )-1\right )}{f c \left (\tan \left (f x +e \right )+i\right )^{2}}\) \(63\)
default \(-\frac {i \sqrt {a \left (1+i \tan \left (f x +e \right )\right )}\, \sqrt {-c \left (i \tan \left (f x +e \right )-1\right )}\, \left (i \tan \left (f x +e \right )-1\right )}{f c \left (\tan \left (f x +e \right )+i\right )^{2}}\) \(63\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+I*a*tan(f*x+e))^(1/2)/(c-I*c*tan(f*x+e))^(1/2),x,method=_RETURNVERBOSE)

[Out]

-I/f*(a*(1+I*tan(f*x+e)))^(1/2)*(-c*(I*tan(f*x+e)-1))^(1/2)/c*(I*tan(f*x+e)-1)/(tan(f*x+e)+I)^2

________________________________________________________________________________________

Maxima [A]
time = 0.55, size = 27, normalized size = 0.66 \begin {gather*} \frac {\sqrt {a} {\left (-i \, \cos \left (f x + e\right ) + \sin \left (f x + e\right )\right )}}{\sqrt {c} f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+I*a*tan(f*x+e))^(1/2)/(c-I*c*tan(f*x+e))^(1/2),x, algorithm="maxima")

[Out]

sqrt(a)*(-I*cos(f*x + e) + sin(f*x + e))/(sqrt(c)*f)

________________________________________________________________________________________

Fricas [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 68 vs. \(2 (33) = 66\).
time = 1.10, size = 68, normalized size = 1.66 \begin {gather*} \frac {\sqrt {\frac {a}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}} \sqrt {\frac {c}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}} {\left (-i \, e^{\left (3 i \, f x + 3 i \, e\right )} - i \, e^{\left (i \, f x + i \, e\right )}\right )}}{c f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+I*a*tan(f*x+e))^(1/2)/(c-I*c*tan(f*x+e))^(1/2),x, algorithm="fricas")

[Out]

sqrt(a/(e^(2*I*f*x + 2*I*e) + 1))*sqrt(c/(e^(2*I*f*x + 2*I*e) + 1))*(-I*e^(3*I*f*x + 3*I*e) - I*e^(I*f*x + I*e
))/(c*f)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\sqrt {i a \left (\tan {\left (e + f x \right )} - i\right )}}{\sqrt {- i c \left (\tan {\left (e + f x \right )} + i\right )}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+I*a*tan(f*x+e))**(1/2)/(c-I*c*tan(f*x+e))**(1/2),x)

[Out]

Integral(sqrt(I*a*(tan(e + f*x) - I))/sqrt(-I*c*(tan(e + f*x) + I)), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+I*a*tan(f*x+e))^(1/2)/(c-I*c*tan(f*x+e))^(1/2),x, algorithm="giac")

[Out]

integrate(sqrt(I*a*tan(f*x + e) + a)/sqrt(-I*c*tan(f*x + e) + c), x)

________________________________________________________________________________________

Mupad [B]
time = 5.38, size = 49, normalized size = 1.20 \begin {gather*} \frac {\sqrt {a\,\left (1+\mathrm {tan}\left (e+f\,x\right )\,1{}\mathrm {i}\right )}\,\sqrt {-c\,\left (-1+\mathrm {tan}\left (e+f\,x\right )\,1{}\mathrm {i}\right )}}{c\,f\,\left (\mathrm {tan}\left (e+f\,x\right )+1{}\mathrm {i}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a*tan(e + f*x)*1i)^(1/2)/(c - c*tan(e + f*x)*1i)^(1/2),x)

[Out]

((a*(tan(e + f*x)*1i + 1))^(1/2)*(-c*(tan(e + f*x)*1i - 1))^(1/2))/(c*f*(tan(e + f*x) + 1i))

________________________________________________________________________________________